package com.project.bean;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.time.LocalDate;

/**
 * 房间设施实体类
 */
@TableName("t_roomSet")
public class RoomSetBean {
    /**
     * 编号
     */
    @TableId(value = "pk_setId", type = IdType.AUTO)
    private Integer id;
    /**
     * 损坏描述
     */
    @TableField("s_info")
    private String info;
    /**
     * 报损日期
     */
    @TableField("s_reportDate")
    private LocalDate reportDate = LocalDate.now();
    /**
     * 是否解决
     */
    @TableField("s_isSolve")
    private String isSolve = "未解决";
    @TableField("fk_roomId")
    private Integer roomId;
    /**
     * 所属房间
     */
    @TableField(exist = false)
    private RoomBean room;

    public RoomSetBean(String info, RoomBean room) {
        this.info = info;
        this.room = room;
    }

    public RoomSetBean(String info, Integer roomId) {
        this.info = info;
        this.roomId = roomId;
    }

    public RoomSetBean() {
    }

    public Integer getRoomId() {
        return roomId;
    }

    public void setRoomId(Integer roomId) {
        this.roomId = roomId;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getInfo() {
        return info;
    }

    public void setInfo(String info) {
        this.info = info;
    }

    public LocalDate getReportDate() {
        return reportDate;
    }

    public void setReportDate(LocalDate reportDate) {
        this.reportDate = reportDate;
    }

    public String getIsSolve() {
        return isSolve;
    }

    public void setIsSolve(String isSolve) {
        this.isSolve = isSolve;
    }

    public RoomBean getRoom() {
        return room;
    }

    public void setRoom(RoomBean room) {
        this.room = room;
    }

    @Override
    public String toString() {
        return "RoomSetBean{" +
                "id=" + id +
                ", info='" + info + '\'' +
                ", reportDate=" + reportDate +
                ", isSolve='" + isSolve + '\'' +
                ", roomId=" + roomId +
                ", room=" + room +
                '}';
    }
}
